package com.example.practice4;

import android.app.Service;
import android.content.Intent;
import android.os.Binder;
import android.os.IBinder;
import android.util.Log;

public class MyService extends Service {
private LocalBinder myBinder = new LocalBinder();

    public MyService() {
    }
public class LocalBinder extends Binder{
      public  MyService getService(){
            return MyService.this;
        }
}
    @Override
    public void onCreate() {
        super.onCreate();
    }

    public int add(int x, int y){
        return x+y;
    }
    public int Times(int x,int y){
        return x*y;
    }
    public   double div(int x,int y){
        return x/y;
    }
    public int sub(int x,int y){
        return x-y;
    }
    @Override
    public IBinder onBind(Intent intent) {
        // TODO: Return the communication channel to the service.
        Log.v("Msg:","My Bonder is create");
        return myBinder;

    }
}